import time
from public.action import *
from public.business import *
from public.testData import *
from public.tools import*
testCase22='DBshop022_删除品牌流程'
firefox=openBrowser(urlAdmin)
DBshopLoginAdmin(firefox)
DBshopEnterMenu2(firefox,'商品管理','商品品牌')#进入商品品牌
firefox.find_element_by_link_text('删除').click() #点击删除
firefox.switch_to.alert.accept()# 处理提示弹窗
time.sleep(3)
try:
    firefox.find_element_by_xpath('//td[text()="暂无商品品牌"]')
    writeLog('%s 测试通过'%testCase22)

except:
    writeLog('%s 测试失败'%testCase22)
    getPhoto(firefox)
firefox.quit()
